package com.ddh.codeduck.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.service.IService;
import com.codeduck.pojo.dto.CodeDuckQuestionDTO;
import com.codeduck.pojo.entity.CodeDuckQuestion;
import com.codeduck.pojo.req.CodeDuckQuestionPageReq;
import com.codeduck.pojo.vo.CodeDuckQuestionVO;

/**
 * <p>
 * 题目表 服务类
 * </p>
 *
 * @author ddh
 * @since 2025-07-04
 */
public interface ICodeDuckQuestionService extends IService<CodeDuckQuestion> {

    /**
     * 根据题目分类查询题目并且分页
     *
     * @param codeDuckQuestionPageReq
     * @return
     */
    IPage<CodeDuckQuestionVO> listByQuestionCategory(CodeDuckQuestionPageReq codeDuckQuestionPageReq);

    /**
     * 新增或者修改题目
     * @param codeDuckQuestionDTO
     * @return
     */
    Boolean mySaveOrUpdateQuestion(CodeDuckQuestionDTO codeDuckQuestionDTO);
}
